package net.cyndeline.rldungeon.dgs.strategy.pointlessArea

import scalax.collection.immutable.Graph
import net.cyndeline.rldungeon.dgs.strategy.help.{CollapsedEdge, CollapsedNode}
import net.cyndeline.rldungeon.dgs.graph.{DGSFunctionality, Room}
import scalax.collection.GraphEdge.UnDiEdge
import scalax.collection.GraphPredef.OuterEdge
import net.cyndeline.rldungeon.dgs.strategy.pointlessArea.algorithms.RemoverSetupData
import scala.reflect.runtime.universe._
import scala.reflect._

/**
 * Specifies the apply method for an object that updates a graph using a cycle-collapsed graph by adding
 * rewards and activator/responders to it.
 */
trait PointlessAreaAlgorithm {
  def apply[VType <: Room[VType]: TypeTag : ClassTag, EType[X] <: UnDiEdge[X] with DGSFunctionality[X, EType] with OuterEdge[X, EType]]
            (graph: Graph[VType, EType],
            cycleCollapsedGraph: Graph[CollapsedNode[VType], CollapsedEdge[VType]#Inner],
            start: CollapsedNode[VType],
            goal: CollapsedNode[VType],
            responderAmountMainPath: Int,
            responderAmountPointlessAreas: Int,
            data: RemoverSetupData[VType, EType]): Graph[VType, EType]
}
